generator: Still create /run/ostree in static prepareroot path
Ref https://github.com/ostreedev/ostree/pull/3406
There's a combination of two commits here that broke the static
prepareroot path:
ec1109c7a93a2ed07503b12ffecf7048cf7cc0d0
"generator: Stop creating `/run/ostree-booted`"
and more recently
b9ce0e89801bbc92d50473d3620b3f41f1dbef9f
generator: Exit if there's no `/run/ostree`
Basically when run via a non-static prepareroot we create
`/run/ostree-booted` consistently in the initramfs,
using the kernel argument presence as source of truth.
But for the static prepareroot, the generator checked
the kernel argument, and had a fallback of creating it.
Except that's busted in the case of running in a
container, where with many runtimes we still
default to seeing the host's commandline (which
is basically wrong...but fixing that requires a
userspace virtualizer/interceptor for `/proc`
so it's not commonly done).
This should fix the static prepareroot path
by detecting the case where we're compiled
with a static prepareroot, and if so we then
hardcode creating the `/run/ostree-booted`
file in the generator. I think basically
everyone who is compiling ostree with
a static prepareroot *and* including it
in their filesystem trees can be pretty
much guaranteed to be actually using it.